import React from 'react';
import { InputNumber, Input, Form } from 'antd';
import _ from 'lodash';
import styles from '../index.less';

const TableInput = props => {
  const { inputref, value, status, onChange } = props;
  // const { inputForm, record, dataIndex } = props;
  return (
    <Form.Item
      style={{ margin: 0 }}
      className={styles['editable-cell-value-input']}
      hasFeedback
      validateStatus={status ? null : 'error'}
    >
      {/* < InputNumber
                step={0.01}
                precision={2}
                min={0}
                max={100}
                formatter={value => `${value}%`}
                ref={inputref}
                {...props}
            /> */}
      <Input ref={inputref} {...props} suffix={'%'} />
    </Form.Item>
  );
};

export default TableInput;
